package com.ujiuye.service;

import com.ujiuye.bean.User;
import com.ujiuye.dao.UserDao;

import java.util.List;

public class UserService {
    public User getUserByNameAndPassword(String username,String pwd){
        if(username!=null && username.trim()!="" && pwd!=null &&pwd.trim()!=null){
            UserDao ud=new UserDao();
            return  ud.getUserByNameAndPassword(username,pwd);
        }else{
            return null;
        }
    }
    public List<User> selectAllUser(){
        UserDao ud = new UserDao();
        return ud.selectAllUser();
    }
}
